
// MIT License
// 
// Copyright (c) 2009-2017 Luca Piccioni
// 
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
// 
// The above copyright notice and this permission notice shall be included in all
// copies or substantial portions of the Software.
// 
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.
// 
// This file is automatically generated

#pragma warning disable 649, 1572, 1573

// ReSharper disable RedundantUsingDirective
using System;
using System.Diagnostics;
using System.Runtime.InteropServices;
using System.Security;
using System.Text;

using Khronos;

// ReSharper disable CheckNamespace
// ReSharper disable InconsistentNaming
// ReSharper disable JoinDeclarationAndInitializer

namespace OpenGL
{
	public partial class Gl
	{
		/// <summary>
		/// [GL] Value of GL_PIXELS_PER_SAMPLE_PATTERN_X_AMD symbol.
		/// </summary>
		[RequiredByFeature("GL_AMD_framebuffer_sample_positions")]
		public const int PIXELS_PER_SAMPLE_PATTERN_X_AMD = 0x91AE;

		/// <summary>
		/// [GL] Value of GL_PIXELS_PER_SAMPLE_PATTERN_Y_AMD symbol.
		/// </summary>
		[RequiredByFeature("GL_AMD_framebuffer_sample_positions")]
		public const int PIXELS_PER_SAMPLE_PATTERN_Y_AMD = 0x91AF;

		/// <summary>
		/// [GL] Value of GL_ALL_PIXELS_AMD symbol.
		/// </summary>
		[RequiredByFeature("GL_AMD_framebuffer_sample_positions")]
		public const uint ALL_PIXELS_AMD = 0xFFFFFFFF;

		/// <summary>
		/// [GL] glFramebufferSamplePositionsfvAMD: Binding for glFramebufferSamplePositionsfvAMD.
		/// </summary>
		/// <param name="target">
		/// A <see cref="T:FramebufferTarget"/>.
		/// </param>
		/// <param name="numsamples">
		/// A <see cref="T:uint"/>.
		/// </param>
		/// <param name="pixelindex">
		/// A <see cref="T:uint"/>.
		/// </param>
		/// <param name="values">
		/// A <see cref="T:float[]"/>.
		/// </param>
		[RequiredByFeature("GL_AMD_framebuffer_sample_positions")]
		public static void FramebufferSampleAMD(FramebufferTarget target, uint numsamples, uint pixelindex, float[] values)
		{
			unsafe {
				fixed (float* p_values = values)
				{
					Debug.Assert(Delegates.pglFramebufferSamplePositionsfvAMD != null, "pglFramebufferSamplePositionsfvAMD not implemented");
					Delegates.pglFramebufferSamplePositionsfvAMD((int)target, numsamples, pixelindex, p_values);
					LogCommand("glFramebufferSamplePositionsfvAMD", null, target, numsamples, pixelindex, values					);
				}
			}
			DebugCheckErrors(null);
		}

		/// <summary>
		/// [GL] glNamedFramebufferSamplePositionsfvAMD: Binding for glNamedFramebufferSamplePositionsfvAMD.
		/// </summary>
		/// <param name="framebuffer">
		/// A <see cref="T:uint"/>.
		/// </param>
		/// <param name="numsamples">
		/// A <see cref="T:uint"/>.
		/// </param>
		/// <param name="pixelindex">
		/// A <see cref="T:uint"/>.
		/// </param>
		/// <param name="values">
		/// A <see cref="T:float[]"/>.
		/// </param>
		[RequiredByFeature("GL_AMD_framebuffer_sample_positions")]
		public static void NamedFramebufferSampleAMD(uint framebuffer, uint numsamples, uint pixelindex, float[] values)
		{
			unsafe {
				fixed (float* p_values = values)
				{
					Debug.Assert(Delegates.pglNamedFramebufferSamplePositionsfvAMD != null, "pglNamedFramebufferSamplePositionsfvAMD not implemented");
					Delegates.pglNamedFramebufferSamplePositionsfvAMD(framebuffer, numsamples, pixelindex, p_values);
					LogCommand("glNamedFramebufferSamplePositionsfvAMD", null, framebuffer, numsamples, pixelindex, values					);
				}
			}
			DebugCheckErrors(null);
		}

		/// <summary>
		/// [GL] glGetFramebufferParameterfvAMD: Binding for glGetFramebufferParameterfvAMD.
		/// </summary>
		/// <param name="target">
		/// A <see cref="T:FramebufferTarget"/>.
		/// </param>
		/// <param name="pname">
		/// A <see cref="T:FramebufferAttachmentParameterName"/>.
		/// </param>
		/// <param name="numsamples">
		/// A <see cref="T:uint"/>.
		/// </param>
		/// <param name="pixelindex">
		/// A <see cref="T:uint"/>.
		/// </param>
		/// <param name="size">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="values">
		/// A <see cref="T:float[]"/>.
		/// </param>
		[RequiredByFeature("GL_AMD_framebuffer_sample_positions")]
		public static void GetFramebufferParameterAMD(FramebufferTarget target, FramebufferAttachmentParameterName pname, uint numsamples, uint pixelindex, int size, [Out] float[] values)
		{
			unsafe {
				fixed (float* p_values = values)
				{
					Debug.Assert(Delegates.pglGetFramebufferParameterfvAMD != null, "pglGetFramebufferParameterfvAMD not implemented");
					Delegates.pglGetFramebufferParameterfvAMD((int)target, (int)pname, numsamples, pixelindex, size, p_values);
					LogCommand("glGetFramebufferParameterfvAMD", null, target, pname, numsamples, pixelindex, size, values					);
				}
			}
			DebugCheckErrors(null);
		}

		/// <summary>
		/// [GL] glGetNamedFramebufferParameterfvAMD: Binding for glGetNamedFramebufferParameterfvAMD.
		/// </summary>
		/// <param name="framebuffer">
		/// A <see cref="T:uint"/>.
		/// </param>
		/// <param name="pname">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="numsamples">
		/// A <see cref="T:uint"/>.
		/// </param>
		/// <param name="pixelindex">
		/// A <see cref="T:uint"/>.
		/// </param>
		/// <param name="size">
		/// A <see cref="T:int"/>.
		/// </param>
		/// <param name="values">
		/// A <see cref="T:float[]"/>.
		/// </param>
		[RequiredByFeature("GL_AMD_framebuffer_sample_positions")]
		public static void GetNamedFramebufferParameterAMD(uint framebuffer, int pname, uint numsamples, uint pixelindex, int size, [Out] float[] values)
		{
			unsafe {
				fixed (float* p_values = values)
				{
					Debug.Assert(Delegates.pglGetNamedFramebufferParameterfvAMD != null, "pglGetNamedFramebufferParameterfvAMD not implemented");
					Delegates.pglGetNamedFramebufferParameterfvAMD(framebuffer, pname, numsamples, pixelindex, size, p_values);
					LogCommand("glGetNamedFramebufferParameterfvAMD", null, framebuffer, pname, numsamples, pixelindex, size, values					);
				}
			}
			DebugCheckErrors(null);
		}

		internal static unsafe partial class Delegates
		{
			[RequiredByFeature("GL_AMD_framebuffer_sample_positions")]
			[SuppressUnmanagedCodeSecurity]
			internal delegate void glFramebufferSamplePositionsfvAMD(int target, uint numsamples, uint pixelindex, float* values);

			[RequiredByFeature("GL_AMD_framebuffer_sample_positions")]
			[ThreadStatic]
			internal static glFramebufferSamplePositionsfvAMD pglFramebufferSamplePositionsfvAMD;

			[RequiredByFeature("GL_AMD_framebuffer_sample_positions")]
			[SuppressUnmanagedCodeSecurity]
			internal delegate void glNamedFramebufferSamplePositionsfvAMD(uint framebuffer, uint numsamples, uint pixelindex, float* values);

			[RequiredByFeature("GL_AMD_framebuffer_sample_positions")]
			[ThreadStatic]
			internal static glNamedFramebufferSamplePositionsfvAMD pglNamedFramebufferSamplePositionsfvAMD;

			[RequiredByFeature("GL_AMD_framebuffer_sample_positions")]
			[SuppressUnmanagedCodeSecurity]
			internal delegate void glGetFramebufferParameterfvAMD(int target, int pname, uint numsamples, uint pixelindex, int size, float* values);

			[RequiredByFeature("GL_AMD_framebuffer_sample_positions")]
			[ThreadStatic]
			internal static glGetFramebufferParameterfvAMD pglGetFramebufferParameterfvAMD;

			[RequiredByFeature("GL_AMD_framebuffer_sample_positions")]
			[SuppressUnmanagedCodeSecurity]
			internal delegate void glGetNamedFramebufferParameterfvAMD(uint framebuffer, int pname, uint numsamples, uint pixelindex, int size, float* values);

			[RequiredByFeature("GL_AMD_framebuffer_sample_positions")]
			[ThreadStatic]
			internal static glGetNamedFramebufferParameterfvAMD pglGetNamedFramebufferParameterfvAMD;

		}
	}

}
